/**
 * @Author: 焦质晔
 * @Date: 2019/6/20
 * @Last Modified by: mikey.zhaopeng
 * @Last Modified time: 2020-01-06 18:45:17
 */
import axios from '@/api/fetch';
import * as types from './types';
import SERVER from '@/api/server';
//  条件查询颜色
export const getColors = params => axios.get(`${SERVER.DMSCLOUD_SYSBASEDATA}/vehicleProduct/colors`, { params });
//  新增一个颜色
export const addColor = params => axios.post(`${SERVER.DMSCLOUD_SYSBASEDATA}/vehicleProduct/colors`, params);
// 修改一个品牌
export const updateColor = (params, id) => axios.put(`${SERVER.DMSCLOUD_SYSBASEDATA}/vehicleProduct/colors/${id}`, params);


// 车厂
//  条件查询颜色
export const getColorsOEM = params => axios.get(`${SERVER.DMSCLOUD_SYSBASEDATA}/dcs/vehicleProduct/colors`, { params });
//  新增一个颜色
export const addColorOEM = params => axios.post(`${SERVER.DMSCLOUD_SYSBASEDATA}/dcs/vehicleProduct/colors`, params);
// 修改一个品牌
export const updateColorOEM = (params, id) => axios.put(`${SERVER.DMSCLOUD_SYSBASEDATA}/dcs/vehicleProduct/colors/${id}`, params);
